<%-------------------------------------------------------------------
 * 页面名称：/page/vnvtools/showChain.jsp
 * 功能描述：支付链查看效果页面
 * Action: 
 *
 *-------------------------------------------------------------------
--%>
<%@ page contentType="text/html; charset=utf-8"%>
<%@ taglib uri="struts-html.tld" prefix="html"%>
<%@ taglib uri="struts-tiles.tld" prefix="tiles"%>
<%@ taglib uri="struts-logic.tld" prefix="logic"%>
<%@ taglib uri="struts-bean.tld" prefix="bean"%>
<%@ page import="cn.agiledata.bank.common.util.Constant"%>
<%
	String path = request.getContextPath();
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="<%=path%>/css/style.css" rel="stylesheet" type="text/css" />
<link href="<%=path%>/css/font.css" rel="stylesheet" type="text/css" />
<link href="<%=path%>/css/newstyle.css" rel="stylesheet" type="text/css" />
<link href="<%=path%>/css/common.css" rel="stylesheet" type="text/css" />
<script type='text/javascript' src='<%=path%>/js/vnv/commonForManage.js'></script>
<script type="text/javascript" src='<%=path%>/js/vnv/commonForMutual.js' language="javascript" charset="UTF-8"></script>
<script type="text/javascript" src="<%=path%>/js/pagetitle.js"></script>
<script type="text/javascript">
function toSubmit(){
	var formObj = document.forms["0"];
	if(checkNecessaryInput(formObj)){
		var debitName = formObj.debitName;
		var amount = formObj.amount.value;
		var debit = formObj.debit;
		var remark = formObj.remark.value;
		
		if(debitName.value.length>64){
			alert("付款人姓名不能超过64个字！");
			debitName.value="";
			debitName.focus();
		}else if(!isNumberFloat(amount)){
			alert("付款金额格式错误，请输入正确的金额！");
			formObj.amount.value = "";
			formObj.amount.focus();
		}else if(parseFloat(amount)<=0){
			alert("付款金额必须大于零！");
			formObj.amount.value = "";
			formObj.amount.focus();
		}else if(matchValidate(getObj("debit"),"URegexType.email|URegexType.mobile","付款方Email或手机") != ""){
				debit.value="";
				debit.focus();
		}else if(remark.length>80){
			alert("附言内容不能超过80个字！");
			formObj.remark.focus();
		}else{
			formObj.amount.value = parseFloat(amount);
			formObj.submit();
		}
	}
}
</script>
</head>
<body>
<div id="mainFrame">
   <div class="rightSider">
      <div class="logined_info2">
      <span class="bluefont18bdrop">
      <a href="<%=path%>/main.do">
      <img src="<%=path%>/images/logo2.gif" border="0" align="absmiddle" /></a> |支付链</span></div> 
	  <div class="edit_pass">
	    <table width="100%" border="0" align="center" cellpadding="5" cellspacing="1">
	      <form action="<%=path%>/chainPay.do" method="post">
           <input type="hidden" name="license" value="">
           <input type="hidden" name="assuredPay" value="false">
	      <tr>
            <td colspan="2" class="orangefont14b">收款人信息</td>
	      </tr>
	      <!-- 收款人姓名 -->
	      <tr>
            <td width="20%" align="right">收款人姓名：</td>
	        <td width="80%" bgcolor="#FFFFFF"><bean:write name="account" property="name"/> </td>
          </tr>
           <!-- 收款人账户 -->
	      <tr>
            <td width="20%" align="right">收款人账户：</td>
            <td width="80%" bgcolor="#FFFFFF">
              <input type="hidden" name="creditId" value="<bean:write name="account" property="id"/>" />
              <logic:notEmpty name="account" property="email">
                 <bean:write name="account" property="email"/>
              </logic:notEmpty>
              <logic:empty name="account" property="email">
                <bean:write name="account" property="mobile"/>
              </logic:empty>
            </td>
         </tr>
   <!-- 认证情况 -->
   <tr>
    <td width="20%" align="right">认证情况：</td>
    <td width="80%" bgcolor="#FFFFFF">
      <logic:equal name="account" property="accountType" value="<%=Constant.ACCOUNT_TYPE_BUYER%>">
		<logic:equal name="ifCardPass" value="Y">
			&nbsp;身份证
		</logic:equal>
		<logic:equal name="ifBank" value="Y">
			&nbsp;银行卡
		</logic:equal>
		<logic:equal name="ifMobileNotPass" value="N">
			&nbsp;手机
		</logic:equal>										
      </logic:equal>
      <logic:equal name="account" property="accountType" value="<%=Constant.ACCOUNT_TYPE_CORPORATION%>">
        <logic:equal name="account" property="auditStatus" value="<%=Constant.NO_AUDIT_STATUS%>">
            &nbsp;未审核
        </logic:equal>
        <logic:equal name="account" property="auditStatus" value="<%=Constant.IN_AUDIT_STATUS%>">
            &nbsp;审核中
        </logic:equal>
        <logic:equal name="account" property="auditStatus" value="<%=Constant.HAVE_AUDIT_STATUS%>">
            &nbsp;已审核
        </logic:equal>
      </logic:equal>
    </td>
  </tr>
  <!--说 明  -->
  <tr>
    <td width="20%" align="right">说 明：</td>
    <td width="80%" bgcolor="#FFFFFF"><bean:write name="account" property="chainRemark" /> </td>
  </tr>
 <!--付款人信息 -->
  <tr>
     <td colspan="2" class="orangefont14b">付款人信息</td>
  </tr> 
  <!-- 付款人姓名 --> 
  <tr>
    <td align="right"><span class="orang12b">*</span> 付款人姓名：</td>
    <td bgcolor="#FFFFFF">
    <input type="text" name="debitName" alt="付款人姓名" maxlength="64" size="40" class="inputStyle" />
    </td>
  </tr>
  <!-- 付款金额 -->
  <tr>
    <td align="right"><span class="orang12b">*</span> 付款金额：</td>
    <td bgcolor="#FFFFFF">
    <input type="text" name="amount" alt="付款金额" size="40" class="inputStyle" onBlur="checkDecimalInput(this,0)" /> 元</td>
  </tr>
 <!--付款方Email或手机-->    
  <tr>
     <td align="right"><span class="orang12b">*</span> 付款方Email或手机：</td>
     <td bgcolor="#FFFFFF"><input type="text" name="debit" maxLength="40" size="40" class="inputStyle" alt="付款方Email或手机" /></td>
  </tr>
 <!-- 附 言 -->  
  <tr>
    <td align="right" valign="top">附 言：</td>
    <td bgcolor="#FFFFFF"><span class="font_blue">
    <textarea name="remark" cols="35" rows="5" style="border:1px solid #ccc;"></textarea>
    <br />
    <span class="font_gray">(字数在80个以内)</span></span></td>
 </tr> 
 <tr>
    <td align="right">&nbsp;</td>
    <td height="50" bgcolor="#FFFFFF">
      <input type="button" name="next" value="下一步" class="button_style" onclick="toSubmit();" style="margin-right:20px;" />
    </td>
 </tr>
  </form>
 </table>
 </div>
 </div>
<script type="text/javascript" src="<%=path%>/js/layer.js"></script>
<script language="JavaScript" type="text/JavaScript">
function amountSelect(){
 	agiledata.getUserInternal(amountPopup);
}
function amountPopup(data) {
  	if(data) {
	 	openLayer("<%=path%>/page/common/simpleCalculator.jsp",400,200,false);
	} else {
		location.href="<%=path%>/page/util/session_invalid.jsp";
	}      
}
</script>
</body>
</html>
   